import java.util.Arrays;

public class SystemTest2 {
    public static void main(String[] args) {
        int[] arr = {10, 20, 30, 40, 50};

//        System.arraycopy(arr, 0, arr, 1, 4);
        System.arraycopy(arr, 1, arr, 0, 4);

        System.out.println("arr的元素：" + Arrays.toString(arr));
        //arr的元素：[10, 10, 20, 30, 40]  相当于右移
        //arr的元素：[20, 30, 40, 50, 50]  相当于左移

    }
}
